package com.example.demo.com.test.tt;

 import nb.com.annotation.TokensLimiter;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.data.redis.core.StringRedisTemplate;
 import org.springframework.stereotype.Service;

/**
 * @author nb
 * @version 1.0
 * @date 2021/11/7 16:37
 */
@Service
public class ttServiceImpl implements ttService{
@Autowired
private StringRedisTemplate stringRedisTemplate;
    @Override
    @TokensLimiter(key="test",max = 5L,timeNum=10L    )
    public void tt() {
        System.out.println("tt");
    }
}
